package com.hp.ssoserver.controller;

import com.hp.ssoserver.entity.User;
import com.hp.ssoserver.service.IUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author huangpeng
 * @Title 订单控制类
 * @Package
 * @Date 2020/8/25 16:16
 * @Description
 * @Version 1.0
 */
@RequestMapping("/user/")
@RestController
public class UserController {
    @Autowired
    private IUserService userService;

    /**
     * 新增用户
     * @param order
     * @return
     */
    @PostMapping("saveUser")
    public boolean saveUser(@RequestBody User order){
        return userService.saveUser(order);
    }
}
